package com.ytkj.digitalConstruction.httpbean.message.reqbean;

import java.util.List;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

import com.ytkj.digitalConstruction.entity.message.Message;

/**
 * 新增消息的参数类
 * 
 * @author momei
 */
public class AddMessageParam extends Message {
	
	@NotNull(message = "接受用户不能为空")
	@Size(min=1 , message = "接受用户不能为空")
	private List<Integer> userIds;
	
	public Message message(){
		Message message = new Message();
		message.setContent(this.getContent());
		message.setPublicDate(this.getPublicDate());
		message.setTitle(this.getTitle());
		message.setType(this.getType());
		message.setMsgType(this.getMsgType());
		return message;
	}

	public List<Integer> getUserIds() {
		return userIds;
	}

	public void setUserIds(List<Integer> userIds) {
		this.userIds = userIds;
	}
}
